package top.llove.controller;

import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import top.llove.service.LoveService;
import top.llove.utils.res.ApiResult;

/**
 * 情话Controller
 *
 * @author: 幸会
 * @date: 2021/7/7 19:11
 * @email: 1846724873@qq.com
 * @description: 情话Controller
 * version: 1.0
 */
@Slf4j
@RestController
@RequestMapping("/love")
public class LoveController {
    @Autowired
    private LoveService love;

    @GetMapping("/s")
    public ApiResult select(@RequestParam(value = "i", required = false) String id,
                            @RequestParam(value = "t", required = false) String text){
        return love.select(id, text);
    }
}
